package com.mingtu.dzpatrol.decoration;

import android.graphics.Rect;
import android.view.View;

import androidx.recyclerview.widget.RecyclerView;

import com.blankj.utilcode.util.SizeUtils;

/**
 * @ClassName :
 * @Author : wkk
 * @Date : 2023-3-14 17:05:50
 * @Email : 1281573890@qq.com
 * @Eescription :
 */
public class LRSpaceItemDecoration extends RecyclerView.ItemDecoration {
    private int mSpace = SizeUtils.dp2px(15);

    public LRSpaceItemDecoration() {

    }

    public LRSpaceItemDecoration(int space) {
        this.mSpace = space;
    }

    @Override
    public void getItemOffsets(Rect outRect, View view, RecyclerView parent, RecyclerView.State state) {
        super.getItemOffsets(outRect, view, parent, state);
        outRect.left = mSpace;
        outRect.right = mSpace;

    }
}

